package com.irdstudio.apicenter.console.service.authenticate;

import java.sql.SQLException;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.irdstudio.apicenter.console.dm.AppWxMenuConfig;
import com.irdstudio.apicenter.console.dm.AppWxMenuConfigDao;

@Service(value = "appWxMenuConfigService")
public class AppWxMenuConfigService {

	@Autowired
	private AppWxMenuConfigDao appWxMenuConfigDao;

	public int insertOne(AppWxMenuConfig appWxMenuConfig) throws SQLException,
			ClassNotFoundException {
		return appWxMenuConfigDao.save(appWxMenuConfig);
	}

	public AppWxMenuConfig queryAppTradePrivate(String recordKey) throws SQLException {
		return appWxMenuConfigDao.queryWithKeys(recordKey);
	}

	public int update(AppWxMenuConfig appWxMenuConfig) throws SQLException,
			ClassNotFoundException {
		return appWxMenuConfigDao.update(appWxMenuConfig);
	}

	public int delete(String recordKey) throws SQLException,
			ClassNotFoundException {
		return appWxMenuConfigDao.delete(recordKey);
	}

}